package com.chengyu.core.saasopenai;

import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.http.HttpMethod;

import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import java.util.Date;
import java.util.Map;

/**
 * @author wangbo
 * @version 1.0
 * @description TODO
 * @date 2023/7/21 11:30 AM
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class OpenApiHttpReq {
    /**
     * url 地址
     */
    @NotEmpty
    private  String url;

    /**
     * http请求类型
     */
    @NotNull
    private HttpMethod httpMethod;

    /**
     * 本次请求时间戳
     */
    @NotNull
    private Date timestamp;
    /**
     * url 地址入参
     */
    private Map<String,String> urlParam;

    /**
     * http 请求头
     */
    private Map<String,String> header;


    /**
     * Post等类型请求的请求体
     */
    private String body;
}
